package cn.kone.service.impl;

import cn.hutool.core.util.IdUtil;
import cn.kone.mapper.DriverPointMapper;
import cn.kone.pojo.DriverPoint;
import cn.kone.service.IDriverPointService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DriverPointServiceimpl implements IDriverPointService {

    @Autowired
    private DriverPointMapper driverPointMapper;

    @Override
    public void save(DriverPoint point) {
        point.setId(IdUtil.createSnowflake(0,0).nextId());
        driverPointMapper.save(point);


    }

    @Override
    public List<DriverPoint> selectByOrderNo(String orderNo) {
        return driverPointMapper.selectByOrderNo(orderNo);
    }
}
